using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;

namespace Ribbon
{
	public class RabButton : Button
	{
		public static readonly DependencyProperty IconSourceProperty;

		public static readonly DependencyProperty IconSourceGrayProperty;

		public static readonly DependencyProperty TextProperty;

		public static readonly DependencyProperty TextHideProperty;

		public ImageSource IconSource
		{
			get
			{
				return (ImageSource)GetValue(IconSourceProperty);
			}
			set
			{
				SetValue(IconSourceProperty, value);
			}
		}

		public ImageSource IconSourceGray
		{
			get
			{
				return (ImageSource)GetValue(IconSourceGrayProperty);
			}
			set
			{
				SetValue(IconSourceGrayProperty, value);
			}
		}

		public string Text
		{
			get
			{
				return (string)GetValue(TextProperty);
			}
			set
			{
				SetValue(TextProperty, value);
			}
		}

		public Visibility TextHide
		{
			get
			{
				return (Visibility)GetValue(TextHideProperty);
			}
			set
			{
				SetValue(TextHideProperty, value);
			}
		}

		static RabButton()
		{
			IconSourceProperty = DependencyProperty.Register("IconSource", typeof(ImageSource), typeof(RabButton));
			IconSourceGrayProperty = DependencyProperty.Register("IconSourceGray", typeof(ImageSource), typeof(RabButton));
			TextProperty = DependencyProperty.Register("Text", typeof(string), typeof(RabButton));
			TextHideProperty = DependencyProperty.Register("TextHide", typeof(Visibility), typeof(RabButton), new PropertyMetadata(Visibility.Visible));
			FrameworkElement.DefaultStyleKeyProperty.OverrideMetadata(typeof(RabButton), new FrameworkPropertyMetadata(typeof(RabButton)));
		}

		public override void OnApplyTemplate()
		{
			base.OnApplyTemplate();
		}
	}
}
